package com.oracle.jimu.action;

import java.util.List;

import com.opensymphony.xwork2.ActionSupport;
import com.oracle.jimu.bean.SuperType;
import com.oracle.jimu.service.SuperTypeService;


public class SuperAction extends ActionSupport {
	
	private SuperTypeService superService;
	private List<SuperType> superList;
	private Integer superid;
	private SuperType supertype;

	
	
	


	public SuperTypeService getSuperService() {
		return superService;
	}
	
	public void setSuperService(SuperTypeService superService) {
		this.superService = superService;
	}
	public List<SuperType> getSuperList() {
		return superList;
	}

	public void setSuperList(List<SuperType> superList) {
		this.superList = superList;
	}

	public Integer getSuperid() {
		return superid;
	}

	public void setSuperid(Integer superid) {
		this.superid = superid;
	}

	public SuperType getSupertype() {
		return supertype;
	}

	public void setSupertype(SuperType supertype) {
		this.supertype = supertype;
	}

	public String superList() {
		superList=superService.getSupers();
		return SUCCESS;
	}
	
	public String toaddSuper(){
		return SUCCESS;
		
	}
	public String addSuper() {
		superService.addSup(supertype);		
		
		return SUCCESS;
	}
	public String delSuper() {
		
		superService.delSup(superid);	
		
		
		return SUCCESS;
	}
	
	@Override
	public String execute() throws Exception {
		// TODO Auto-generated method stub
		return SUCCESS;
	}
}
